//
//  HLJDeviceDataMacro.h
//  ChatDemo-UI2.0
//
//  Created by 崔志伟 on 2017/12/22.
//  Copyright © 2017年 崔志伟. All rights reserved.
//

#ifndef JBWDeviceDataMacro_h
#define JBWDeviceDataMacro_h

#pragma mark - >>>>>>>> 屏幕尺寸 <<<<<<<<<
#define JBW_KEY_WINDOW [[UIApplication sharedApplication].delegate window]

/**
 *  主屏的宽
 */
#define JBW_SCREEN_WIDTH [[UIScreen mainScreen] bounds].size.width

/**
 *  主屏的高
 */
#define JBW_SCREEN_HEIGHT [[UIScreen mainScreen] bounds].size.height

/**
 *  主屏的size
 */
#define JBW_SCREEN_SIZE   [[UIScreen mainScreen] bounds].size

/**
 *  主屏的frame
 */
#define JBW_SCREEN_FRAME  [UIScreen mainScreen].bounds



//登录界面背景的宽度
#define MAIN_BG_VIEW_WIDTH 380.0f

// 个人中心背景的宽度
#define JBW_PERSON_BG_VIEW_WIDTH  JBW_SCREEN_WIDTH*0.55

// 右侧TabBarView的宽度
#define JBW_TABBAR_VIEW_WIDTH 60.0f







//获取状态栏的高度
#define Status_Height [UIApplication sharedApplication].statusBarFrame.size.height
//安全区底部高度
#define SafeAreaBottomHeight (iPhoneX ? 34 : 0)
//状态栏+导航栏高度
#define  StatusBarAndNavigationBarHeight  (iPhoneX ? 88.f : 64.f)



#define iPhone5 ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(640, 1136), [[UIScreen mainScreen] currentMode].size) : NO)
#define iPhone6 ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(750, 1334), [[UIScreen mainScreen] currentMode].size) : NO)
#define iPhone6P ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1242, 2208), [[UIScreen mainScreen] currentMode].size) : NO)
#define iPhone7 ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(750, 1334), [[UIScreen mainScreen] currentMode].size) : NO)
#define iPhone7P ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1242, 2208), [[UIScreen mainScreen] currentMode].size) : NO)
#define iPhoneX ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1125, 2436), [[UIScreen mainScreen] currentMode].size) : NO)



#define IOS11_OR_ABOVE (([[[UIDevice currentDevice] systemVersion] intValue] >= 11) ? YES : NO)
#define IOS8_OR_ABOVE (([[[UIDevice currentDevice] systemVersion] intValue] >= 8) ? YES : NO)
#define IOS7_OR_ABOVE (([[[UIDevice currentDevice] systemVersion] intValue] >= 7) ? YES : NO)




#endif /* FQBDeviceDataMacro_h */
